#include <stdio.h>
int main() {
    int count,number,sum,i;
    count = 0;
    printf("enter a number:\n");
    scanf("%d",&number);
    sum = 0;
    if(number<0){
        number = -number;
    }
    do{
        i = number%10;
        sum = sum +i;
        number = number/10;
        count++;
    }
    while(number != 0);
    printf("it contains %d digits.\n",count);
    printf("digital sum is %d\n",sum);
    return 0;
}
